#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
#define rep(i, a, b) for (int i = (a); i <= (b); i++)
#define per(i, a, b) for (int i = (a); i >= (b); i--)
#define endl '\n'
const int N = 2e5 + 5;

mt19937 mt(chrono::steady_clock::now().time_since_epoch().count());
int n, m;
int a[N << 1];
ll sum[N << 1], sum2[N << 1];
void solve() {
  cin >> n;
  rep(i, 1, n * 2) cin >> a[i];
  rep(i, 1, n * 2) sum[i] = sum[i - 1] + a[i];
  rep(i, 1, n * 2) {
    if (i & 1)
      sum2[i] = sum2[i - 1] - a[i];
    else
      sum2[i] = sum2[i - 1] + a[i];
  }
  rep(i, 1, n) {
    ll head = sum[i], tail = sum[n * 2] - sum[n * 2 - i];
    ll mid = abs(sum2[n * 2 - i] - sum2[i]);
    cout << tail - head - mid << ' ';
  }
  cout << endl;
}
int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int t;
  cin >> t;
  while (t--) solve();
  return 0;
}